# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
# Maintainer: Jan de Groot <jgc@archlinux.org>

pkgname=libdazzle
pkgver=3.30.1
pkgrel=1
pkgdesc="A library to delight your users with fancy features"
url="https://gitlab.gnome.org/GNOME/libdazzle"
arch=(x86_64)
license=(LGPL)
depends=(gtk3)
makedepends=(git meson vala gobject-introspection gtk-doc)
checkdepends=(xorg-server-xvfb)
_commit=9dbb543e273d70f3df023e9f519f4e37d41e63c5  # tags/3.30.1^0
source=("git+https://gitlab.gnome.org/GNOME/libdazzle.git#commit=$_commit")
sha256sums=('SKIP')

pkgver() {
  cd $pkgname
  git describe --tags | sed 's/-/+/g'
}

build() {
  arch-meson $pkgname build -D enable_gtk_doc=true
  ninja -C build
}

check() {
  xvfb-run dbus-run-session meson test -C build
}

package() {
  DESTDIR="$pkgdir" meson install -C build
}
